04. Finding Diffs Between Larger Files

Finding Diffs Between Larger Files

Question:

Start Quiz:

Solution:

INSTRUCTOR NOTE:

Asteroids Game

If you're interested, you can play the Asteroids game on Doug's website.

Downloading the old and new versions of the file

The two versions of the game.js file are - game_old.js and game_new.js. Here's how to get them on to your computer:

  • Right or Control+click on the file link and and choose Save As

Make sure to take note of where you download them!

When showing the output of running diff on Mac, Caroline accidentally showed the output of diff -u game_new.js game_old.js, that is, she put the files in the incorrect order. (She showed typing the correct command, but the output shown is from running the command with the arguments reversed). If you've run your command correctly, your output should be the reverse of Caroline's: that is, you should see minus signs where she has plus signs and vice versa.